<%@ page language="java" contentType="text/html; charset=UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
	<head>
		<title><s:property value='%{getText("reportSearch_title")}' /></title>
		<link href="/SCMDB/style/main.css" rel="stylesheet" type="text/css" />
		<script type="text/javascript" src="/SCMDB/js/Super.js"></script>
		<%@ include file="../commonPage/message.jsp" %>
		<script type="text/javascript">
		function setTab(m,n){
			 var tli=document.getElementById("menu"+m).getElementsByTagName("li");
			 var mli=document.getElementById("main"+m).getElementsByTagName("div");
			 for(i=0;i<tli.length;i++){
			  tli[i].className=i==n?"hover":"";
			  mli[i].style.display=i==n?"block":"none";
			 }
		}
		function initializeMap(){	
			var mapDiv=$("main0");
			var mapDx,mapDy;
			if(document.uniqueID){ 
				if(parent.hiddenFlag==false){//暂时在IE8中有问题
					mapDx= parseInt(parent.document.body.offsetWidth)-200;
					mapDy=parseInt(parent.document.body.offsetHeight)-80;
				}else{
					mapDx= parseInt(parent.document.body.offsetWidth)-22;
					mapDy=parseInt(parent.document.body.offsetHeight)-80;
				}
		       
		     }else{
		     	if(parent.hiddenFlag==false){ 
		     		mapDx = parseInt(parent.document.body.offsetWidth)-200;
					mapDy = parseInt(parent.document.body.offsetHeight)-140;
		     	}else{
		     		mapDx = parseInt(parent.document.body.offsetWidth)-27;
					if(parent.screenFlag==false){
						mapDy = parseInt(parent.document.body.offsetHeight)-105;
					}else{
						mapDy = parseInt(parent.document.body.offsetHeight)-70;
					}
		     	}
		        
		     }
		     mapDiv.getElementsByTagName("div")[0].style.width=mapDx+"px";
			 mapDiv.getElementsByTagName("div")[0].style.height=mapDy+"px";
			 mapDiv.getElementsByTagName("div")[1].style.width=mapDx+"px";
			 mapDiv.getElementsByTagName("div")[1].style.height=mapDy+"px";
		 }
		 window.onload=function(){
		 	initializeMap();
		 }
		 window.onresize=function(){
		 	initializeMap();
		 }
	</script>
	</head>
	<body>
		<h2>
			<s:property value='%{getText("current_position")}' />${parentMenu}>>${currentMenu}
		</h2>
        	<div class="main" style="border:0px solid red;">
          <ul class="menu0" id="menu0">
            <li onclick="setTab(0,0)" class="hover"><s:property value='%{getText("reportSearch_ri")}' /></li>
            <li onclick="setTab(0,1)"><s:property value='%{getText("reportSearch_yue")}' /></li>
          </ul>
                   
          <div class="main0" id="main0" style="border:0px solid red;">
          	<div style=""><iframe name="main"  src="empReportAction!initDayReport.action" frameborder="0" style="width:100%;height:100%;" scrolling="auto" ></iframe></div>
			<div style="display:none;"><iframe name="main"  src="empReportAction!initMonthReport.action" frameborder="0" style="width:100%;height:100%;" scrolling="auto" ></iframe></div>          
          </div>
          </div>
	</body>
</html>
